put "item1;item2 is bold <B;(-Item3 is Disabled;item4 with macro /Q" into k
put item 1 of it into b
put item 4 of it into a
put popupnum(a,b+1,k) into m
end mousedown
-- part contents for background part 17
----- text -----
PopUpNum
-- part contents for background part 18
----- text -----
Gary Bond
-- part contents for background part 19
----- text -----
XFCN
-- part contents for background part 20
----- text -----
PopUpNum(top,left,"MenuStr")
-- part contents for background part 21
----- text -----
This extremely handy function lets you use popup menus. Use it in conjunction with a button for a pseudomenu. The menu string is a list of menu items separated by semicolons. If you are familiar with metacharacters used with menus, you can use those too. See the card button "TryMe" for a testdrive.
-- part contents for background part 23
----- text -----
on mousedown
put "Apple;Orange;Banana;Kiwi" into menustr
put popupnum(50,65,menustr) into itemnumber
end mousedown
on mousedown
get the rect of the target
put "item1;item2 is bold <B;(-Item3 is Disabled;item4 with macro /Q"     into k